<xsl:stylesheet version="1.0"
                exclude-result-prefixes="xsd xsi oracle-xsl-mapper xsl ns0 tns oraxsl DVMFunctions BasicCredentialsUserFunction UUIDUserFunction IsUserInRoleFunction IsUserInGroupFunction XrefFunctions"
                xmlns:oraxsl="http://www.oracle.com/XSL/Transform/java"
                xmlns:DVMFunctions="http://www.oracle.com/XSL/Transform/java/com.bea.wli.sb.functions.dvm.DVMFunctions"
                xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                xmlns:BasicCredentialsUserFunction="http://www.oracle.com/XSL/Transform/java/com.bea.wli.sb.stages.functions.BasicCredentialsUserFunction"
                xmlns:UUIDUserFunction="http://www.oracle.com/XSL/Transform/java/com.bea.wli.sb.stages.functions.UUIDUserFunction"
                xmlns:oracle-xsl-mapper="http://www.oracle.com/xsl/mapper/schemas"
                xmlns:tns="http://xmlns.oracle.com/pcbpel/adapter/db/sp/AllocateSlotsDB"
                xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
                xmlns:IsUserInRoleFunction="http://www.oracle.com/XSL/Transform/java/com.bea.wli.sb.stages.functions.IsUserInRoleFunction"
                xmlns:ns0="saibot.airport/services/slot"
                xmlns:IsUserInGroupFunction="http://www.oracle.com/XSL/Transform/java/com.bea.wli.sb.stages.functions.IsUserInGroupFunction"
                xmlns:XrefFunctions="http://www.oracle.com/XSL/Transform/java/com.bea.wli.sb.functions.xref.XrefFunctions"
                xmlns:reference="saibot.airport/data/reference" xmlns:common="saibot.airport/data/common">
  <oracle-xsl-mapper:schema>
    <!--SPECIFICATION OF MAP SOURCES AND TARGETS, DO NOT MODIFY.-->
    <oracle-xsl-mapper:mapSources>
      <oracle-xsl-mapper:source type="XSD">
        <oracle-xsl-mapper:schema location="../Schemas/SlotService.xsd"/>
        <oracle-xsl-mapper:rootElement name="allocateSlotRequestMessage" namespace="saibot.airport/services/slot"/>
      </oracle-xsl-mapper:source>
    </oracle-xsl-mapper:mapSources>
    <oracle-xsl-mapper:mapTargets>
      <oracle-xsl-mapper:target type="XSD">
        <oracle-xsl-mapper:schema location="../Resources/AllocateSlotsDB_sp.xsd"/>
        <oracle-xsl-mapper:rootElement name="InputParameters"
                                       namespace="http://xmlns.oracle.com/pcbpel/adapter/db/sp/AllocateSlotsDB"/>
      </oracle-xsl-mapper:target>
    </oracle-xsl-mapper:mapTargets>
    <!--GENERATED BY ORACLE XSL MAPPER 12.1.2.0.0(XSLT Build 130601.2155.4487) AT [MON DEC 30 10:33:57 CET 2013].-->
  </oracle-xsl-mapper:schema>
  <!--User Editing allowed BELOW this line - DO NOT DELETE THIS LINE-->
  <xsl:template match="/">
    <tns:InputParameters>
      <tns:P_SLOTS>
        <tns:P_SLOTS_ITEM>
          <tns:AIRCARRIER_CODE>
            <xsl:value-of select="/ns0:allocateSlotRequestMessage/ns0:Carrier"/>
          </tns:AIRCARRIER_CODE>
          <tns:TIMEBLOCK>
            <tns:START_DATE>
              <xsl:value-of select="/ns0:allocateSlotRequestMessage/ns0:TimePlanningUnit/reference:startDate"/>
            </tns:START_DATE>
            <tns:END_DATE>
              <xsl:value-of select="/ns0:allocateSlotRequestMessage/ns0:TimePlanningUnit/reference:endDate"/>
            </tns:END_DATE>
            <tns:DAYS_OF_WEEK>
              <xsl:for-each select="/ns0:allocateSlotRequestMessage/ns0:TimePlanningUnit/reference:DaysOfWeek/reference:day">
                <tns:DAYS_OF_WEEK_ITEM>
                  <xsl:value-of select="substring (text(), 1, 3 )"/>
                </tns:DAYS_OF_WEEK_ITEM>
              </xsl:for-each>
            </tns:DAYS_OF_WEEK>
            <tns:HOUR_OF_DAY>
              <xsl:value-of select="/ns0:allocateSlotRequestMessage/ns0:TimePlanningUnit/reference:HourOfDay"/>
            </tns:HOUR_OF_DAY>
            <tns:FIVE_MINUTE_BLOCK>
              <xsl:value-of select="/ns0:allocateSlotRequestMessage/ns0:TimePlanningUnit/reference:FiveMinuteBlock"/>
            </tns:FIVE_MINUTE_BLOCK>
          </tns:TIMEBLOCK>
          <tns:ARRIVAL_OR_DEPARTURE>
            <xsl:value-of select="/ns0:allocateSlotRequestMessage/ns0:ArrivalOrDeparture"/>
          </tns:ARRIVAL_OR_DEPARTURE>
          <tns:AIRCRAFT_MODEL_IATA_CODE>
            <xsl:value-of select="/ns0:allocateSlotRequestMessage/ns0:AircraftModel"/>
          </tns:AIRCRAFT_MODEL_IATA_CODE>
          <tns:AIRCRAFT_MODEL_ICAO_CODE/>
        </tns:P_SLOTS_ITEM>
      </tns:P_SLOTS>
    </tns:InputParameters>
  </xsl:template>
</xsl:stylesheet>